package club.banyuan;

public class Main {

    public static void main(String[] args) {
        for (Weekday value : Weekday.values()) {
            printInfo(value);
        }

        Weekday sat = Weekday.SATURDAY;
        for (Weekday day : Weekday.values()) {
            System.out.println(day.compareTo(sat));
            if (day.compareTo(sat)<0)
                System.out.println(day.getDay() + "小于" + sat.getDay());
            else if (day.compareTo(sat) == 0)
                System.out.println(day.getDay() + "等于" + sat.getDay());
            else
                System.out.println(day.getDay() + "大于" + sat.getDay());
        }
    }

    public static void printInfo(Weekday weekday) {
        if (weekday.isHoliday())
            System.out.println(weekday.getDay() + "是假日！");
        else
            System.out.println(weekday.getDay() + "不是假日！");
    }
}
